/*structure.h*/
#pragma once
#include "unit.h"
#include "matrix.h"

using namespace std;

class structure {
private:
	int node_num = 0;
	int unit_num = 0;
	vector<node>snode;
	vector<unit>sunit;
	bool find_node(int u_in, int n_in);
public:
	structure();
	int unum() { return this->unit_num; };
	double Ksum(int f1, int f2, double E, double nu, double t);
	Matrix unit_B(int index);
	Matrix unit_S(int index, double E, double nu);
	Matrix unit_d(int index, vector<double> delta_s);
	Matrix d_xy(double x, double y, vector<double> delta_s);
};